import request from '@/utils/request';
//查询全部学员数据
export const queryAllApi = (name,degree,clazzId,page,pageSize) =>
   request.get(`/students?name=${name}&degree=${degree}&clazzId=${clazzId}&page=${page}&pageSize=${pageSize}`);
//添加学员数据
export const addApi = (student) => request.post('/students', student);

// 查询所有班级数据
export const queryAllClazzApi = () => request.get('/clazzs/list');
// 根据id查询学员数据(路径参数)
export const queryByIdApi = (id) => request.get(`/students/${id}`);
// 修改学员数据
export const updateApi = (student) => request.put('/students', student);
// 违纪处理 /students/violation/{id}/{score}
export const violationApi = (id,score) => request.put(`/students/violation/${id}/${score}`);
// 删除学员数据 /students/{ids}
export const deleteApi = (ids) => request.delete(`/students/${ids}`);